package org.xydpeng.framework.l2cache.support;

import java.util.Objects;
import java.util.concurrent.ScheduledThreadPoolExecutor;
import java.util.concurrent.TimeUnit;

/**
 * @author xydpeng
 * @version v1.0
 * @date: 2024/6/7
 * @description:
 */
public class CacheScheduler {

    public static ScheduledThreadPoolExecutor scheduledThreadPool;

    public static void schedule(Runnable runnable, long delay) {
        Objects.requireNonNull(scheduledThreadPool).schedule(runnable, delay, TimeUnit.MILLISECONDS);
    }
}
